MacGrid is a very simple program based on simple logic. Upon choosing the difficulty level, you are presented with a grid of squares. Your objective is to determine which of those squares contain mines and which do not.
To do this, begin by clicking on any square in the grid. If you are lucky, it will not contain a mine, but will instead change to either a number or a blank square. This number or empty square tells you how many mines are in the immediately surrounding eight squares (six if you clicked on a side square, or three if you clicked on a corner square). If the square is empty, it means that there are NO mines in the surrounding squares. You then continue clicking on squares using the numbers they provide, trying to click on all safe squares and avoiding all squares with mines. To aid you in remembering which squares have mines, you can hold down the Command key and click on a square that you think contains a mine. This will put a "flag" on that square, and from then on you cannot click on the square accidentally (the game just won't let you!) If you think you "flagged" a square incorrectly, simply Command-Click it again, and the flag will disappear. At the bottom of the game board, you will see an icon for a watch and a mine. The timer on the left starts when you click on the first square, and stops ONLY when you die or win... It will NOT stop if MacGrid is put in the background (no cheating now :), but you can 'pause' the game if necessary. The board will be hidden until you 'unpause.' The mine icon and associated number indicate how many mines you have left to flag. Note: the number is based on the number of FLAGS you have set -- this counter doesn't care if the flags are right or not!
The game ends when you either reveal a mine, or have found ALL the safe squares AND have flagged ALL the mine squares. If you reveal a mine, the program will "explode," and then show you where all the mines are. Any squares that you marked as mines that are not really mines will have a yellow X on them. If you want to continue playing MacGrid, you have to start a new game. If you win, and your score is fast enough, you will be asked for your name. (If you want to clear the high scores, simply drag the 'MacGrid Highs' file to the Trash. The game will automatically create a new, empty file.) Your name and time will be placed in the appropriate Roster for the level you completed. You can then start a new game, or quit.
Known Bug: Sometimes MacGrid will crash as it tries to enter your name into the high score list. This is a weird bug as I've only seen it when you win on the Medium level, and then only some of the time! Also, the error message is 'Out of Memory'! I noticed after seeing this several times that my High Score file had some weird stuff in it, so I deleted it and after that the game worked fine! I have been unable to duplicate the bug since then, so if it happens to you, please do the following:
1) write to me and tell me what you were doing when it happened, etc.
2) look at the strings in the High Scores file using ResEdit. The STR resources should
be of length 251 and 61 bytes for Names and Times, respectively. If the resources
have different lengths or appear otherwise corrupted, Trash your High Scores file.
This game was written in THINK Pascal 4.0, primarily between the hours of10:00pm and 2:00am during February, 1993. I missed my "Minesweeper™" for Windows™ in the PC world, and so decided to implement my own version for the Macintosh. Many thanx go to the readers of 'comp.sys.mac.programmer' for their answers to my late-night questions on random number generators, memory allocation, and dialog boxes! Additional thanx go to Lim Unlimited for Lloyd Lim's "Default CDEF," a very nice CDEF that puts outlines around the default button in a dialog box. (The Default CDEF docs are included in the official release of this package, and you can extract the CDEF using ResEdit -- its the only CDEF in MacGrid.)
MacGrid has been written and tested on a Mac IIsi under System 7.0.1+TuneUp 1.1.1, and tested on a Mac LC II and SE/30. If I get around to it, it will eventually get tested on the Mac Classics and IIci's in Cornell's various labs, but right now (Feb 6, 11:14pm) its just too damn cold to walk over there! I have run it under B&W, 4, 16, and 256 colors, with no problems (it looks MUCH better in 256) and it seems to background with no problems. However, I take NO RESPONSIBILITY for any problems occurring due to the use of MacGrid. If it doesn't work, don't use it!
You can use MacGrid for as long as you like, but if you find yourself using it extensively (read "are you addicted yet?"), please send me a postcard or even just e-mail! I'd like to see how far this thing gets, and if I get enough positive response, I may even implement some other ideas if people have interesting ones. You can reach me at the addresses below!
I'm a (almost) 19-yr-old freshman at Cornell University in Ithaca, NY, and probably will be majoring in Computer Science. I program mostly in Pascal, although I'm learning C and Unix. No matter what the quote below says, I do use the MS-DOS world for occassional programming (look for a VGA game from 'Schwiebert and Russo', hopefully to be done by the end of this semester.
enjoy!! -- Erik --
p.s. "Friends don't let friends run Windows™!" -- Anonymous
College address (until May 1993): College Address (August 1993 - May 1994)
Erik Schwiebert Erik Schwiebert
Room 4, Founders Hall Rm 6154, North Campus #6
Cornell University Cornell University
Ithaca, NY 14853-5106 Ithaca, NY 14853-6004
Home address (mail will be forwarded to me at college):
Erik Schwiebert
R.D. #1 Box 1326
Brandon, VT 05733
E-mail:
Internet: evs1@cornell.edu
Fidonet: Erik Schwiebert @ 1:325/111 or 1:325/202
(I don't read my Fidonet mail much anymore, but I do check into 325/111 about once a month. I read my internet mail about 3x a day usually, so thats the fastest way to reach me! Also, if you do write to me at my home address, please indicate on the outside of the envelope that my parents are to forward it to me at college (note: my parents, not the Post Office!) Again, internet is probably the fastest, and i can ALMOST guarantee a response!)